package com.maomao.template.dao;

import com.maomao.template.bean.Role;
import org.springframework.jdbc.core.BeanPropertyRowMapper;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created by admin on 2018/4/12.
 */

@Repository
public class RoleDao extends BaseDao {

    public List<Role> selectAllRole() {
        String sql="SELECT * FROM role";
        return jdbcTemplate.query(sql, BeanPropertyRowMapper.newInstance(Role.class));
    }

}
